public class d1 {
    public static void main(String[] args) {
        f(5);
    }

    public static void f(int depth) {
        for (int i = 0; i < depth; i++) {
            System.out.printf("   ");
        }
        System.out.println(depth);
        if (depth == 0)
            return;
        f(depth-1);
        for (int i = 0; i < depth; i++) {
            System.out.printf("   ");
        }
        System.out.println(depth);
    }
}
